<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
	xmlns:h="http://java.sun.com/jsf/html"
	xmlns:f="http://java.sun.com/jsf/core"
	xmlns:ui="http://java.sun.com/jsf/facelets"
	xmlns:p="http://primefaces.org/ui"
	xmlns:c="http://java.sun.com/jsp/jstl/core">
<h:head>

	<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
	<title>Agility MeEter</title>

	<link
		href="#{facesContext.externalContext.requestContextPath}/css/bootstrap.css"
		rel="stylesheet" type="text/css" />

	<link
		href="#{facesContext.externalContext.requestContextPath}/css/sistema.css"
		rel="stylesheet" type="text/css" />

	<script type="text/javascript"
		src="#{facesContext.externalContext.requestContextPath}/js/sistema.js"></script>

	<script type="text/javascript"
		src="#{facesContext.externalContext.requestContextPath}/js/bootstrap-button.js"></script>

	<script type="text/javascript"
		src="#{facesContext.externalContext.requestContextPath}/js/bootstrap-dropdown.js"></script>

	<script type="text/javascript"
		src="#{facesContext.externalContext.requestContextPath}/js/bootstrap-modal.js"></script>

	<script type="text/javascript"
		src="#{facesContext.externalContext.requestContextPath}/js/bootstrap-scrollspy.js"></script>

	<script type="text/javascript"
		src="#{facesContext.externalContext.requestContextPath}/js/bootstrap-tab.js"></script>

	<script type="text/javascript"
		src="#{facesContext.externalContext.requestContextPath}/js/bootstrap-twipsy.js"></script>

</h:head>
<h:body>
	<p:layout fullPage="true">
		<div style="z-index: 200; position: absolute;">
			<p:layoutUnit position="north">
				<h:form>
					<div class="navbar navbar-inverse navbar-fixed-top">
						<div class="navbar-inner">
							<div class="container-fluid">
								<a class="btn btn-navbar" data-toggle="collapse"
									data-target=".nav-collapse"> <span class="icon-bar"></span>
									<span class="icon-bar"></span> <span class="icon-bar"></span>
								</a> <a class="brand" href="#">Agility MeEter</a>
								<div class="nav-collapse collapse">
									<p class="navbar-text pull-right">
										<h:outputText
											rendered="#{sessionScope['NOME_USUARIO'] != null}"
											value="Logado como #{sessionScope['NOME_USUARIO']}" />
									</p>

									<p class="navbar-text pull-right">
										<h:commandLink
											rendered="#{sessionScope['NOME_USUARIO'] == null}"
											value="Cadastre-se Aqui" styleClass="navbar-link"
											action="#{usuarioAction.telaManterUsuario}" />
									</p>
									<ul class="nav">
										<li class="active"><h:commandLink value="Home" /></li>
										<c:if test="#{sessionScope['NOME_USUARIO'] != null}">
											<li class="dropdown"><a href="#" class="dropdown-toggle"
												data-toggle="dropdown">Atividades<b class="caret"></b></a>
												<ul class="dropdown-menu">
													<li><a href="#">Atividades</a></li>
													<li><a href="#">Minhas Atividades</a></li>
												</ul></li>
										</c:if>
											<c:if test="#{sessionScope['NOME_USUARIO'] != null}">
												<li class="dropdown"><a href="#"
													class="dropdown-toggle" data-toggle="dropdown">Equipes<b
														class="caret"></b></a>
													<ul class="dropdown-menu">
														<li><h:commandLink value="Nova Equipe"
																action="equipe.manter"
																rendered="#{sessionScope['ID_EQUIPE_USUARIO'] == null and sessionScope['ID_USUARIO'] != null}" /></li>
														<li><h:commandLink value="Informações da Equipe"
																action="#{equipeAction.informacoesEquipe()}"
																rendered="#{sessionScope['ID_EQUIPE_USUARIO'] != null and sessionScope['ID_USUARIO'] != null}" /></li>
													</ul></li>
											</c:if>
											<li class="dropdown"><a href="#" class="dropdown-toggle"
												data-toggle="dropdown">Opções <b class="caret"></b></a>
												<ul class="dropdown-menu">
													<li class="divider"></li>
													<li class="nav-header">Meu Menu</li>
													<li><h:commandLink value="Login"
															action="#{usuarioAction.telaLogin()}"
															rendered="#{sessionScope['NOME_USUARIO'] == null}" /></li>
													<li><h:commandLink value="Minhas Informações"
															action="#{usuarioAction.telaManterUsuario()}"
															rendered="#{sessionScope['NOME_USUARIO'] != null}" /></li>
													<li><h:commandLink value="Logout"
															action="#{usuarioAction.logout()}"
															rendered="#{sessionScope['NOME_USUARIO'] != null}" /></li>
												</ul></li>
									</ul>
								</div>
							</div>
						</div>
					</div>
				</h:form>
			</p:layoutUnit>
		</div>
		<p:layoutUnit position="center">
			<h:graphicImage value="/img/fundo.jpg"
				style="background-repeat: no-repeat; position: absolute; height: 99%; width:100%;" />
			<p:growl autoUpdate="true" life="4000" showDetail="true"></p:growl>
			<div id="container"
				style="height: 480px; left: 30%; margin: -240px 0 0 -320px; position: absolute; top: 50%; width: 640px">
				<ui:insert name="corpo">
				</ui:insert>
			</div>
		</p:layoutUnit>

		<p:layoutUnit position="south" size="35">
			<div class="navbar navbar-inverse navbar-fixed-bottom">
				<div class="navbar-inner">
					<div class="container-fluid">
						<p class="navbar-text" style="text-align: center;">Agility
							MeEter, Todos os Direitos Reservados a Supremu's Software</p>
						<!--/.nav-collapse -->
					</div>
				</div>
			</div>
		</p:layoutUnit>
	</p:layout>
</h:body>
</html>